<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>grid网格布局</title>
    <style>
        .box{
            width: 800px;
            height: 800px;
            background-color: beige;
            display: grid;
            /* grid-template-columns: 50% 50%; */
            /* grid-template-rows: 25% 25% 25% 25%; */
            grid-template-columns: repeat(2,200px);
            grid-template-rows: repeat(4,25%);
        }
        .son{
            width: 200px;
            height: 200px;
            background-color: pink;
            border: 1px solid orange;
            box-sizing: border-box;
        }
    </style>
</head>
<body>
    <div class="box">
        <div class="son"></div>
        <div class="son"></div>
        <div class="son"></div>
        <div class="son"></div>
        <div class="son"></div>
        <div class="son"></div>
        <div class="son"></div>
        <div class="son"></div>
    </div>
</body>
</html>